package com.kamistoat.meimeimall.meimeimallorder.dao;

import com.kamistoat.meimeimall.common.annotation.AutoFillCreateTime;
import com.kamistoat.meimeimall.meimeimallorder.entity.OrderSubOrderRelationEntity;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * 总订单和拆分后子订单的关系
 *
 * @author kamistoat
 * @email linjianshanke@163.com
 * @date 2021-09-12 16:42:29
 */
@Mapper
public interface OrderSubOrderRelationDao {
    @AutoFillCreateTime
    Long insert(@Param("entity") OrderSubOrderRelationEntity orderSubOrderRelationEntity);

    List<Long> insertBatch(@Param("entityList") List<OrderSubOrderRelationEntity> orderSubOrderRelationEntities);

    /**
     * 查子订单SN列表
     * @param orderSn
     * @return
     */
    List<String> selectSubOrderSnByOrderSn(@Param("orderSn") String orderSn);
}
